<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>LTE-UNB: Grid/Grid.h Source File</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />

<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">LTE-UNB
   
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.6.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="headertitle">
<div class="title">Grid/Grid.h</div>  </div>
</div><!--header-->
<div class="contents">
<a href="_grid_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 
<a name="l00018"></a>00018 <span class="preprocessor">#ifndef _Grid_h_</span>
<a name="l00019"></a>00019 <span class="preprocessor"></span><span class="preprocessor">#define _Grid_h_</span>
<a name="l00020"></a>00020 <span class="preprocessor"></span>
<a name="l00021"></a>00021 <span class="preprocessor">#include &quot;User.h&quot;</span>
<a name="l00022"></a>00022 <span class="preprocessor">#include &quot;<a class="code" href="_e_node_b_8h.html">ENodeB.h</a>&quot;</span>
<a name="l00023"></a>00023 
<a name="l00024"></a>00024 <span class="keyword">using namespace </span>itpp;
<a name="l00025"></a>00025 <span class="keyword">using namespace </span>std;
<a name="l00026"></a>00026 
<a name="l00031"></a><a class="code" href="namespace_grid.html">00031</a> <span class="keyword">namespace </span><a class="code" href="class_grid_1_1_grid.html">Grid</a>
<a name="l00032"></a>00032 {
<a name="l00033"></a>00033 
<a name="l00038"></a><a class="code" href="class_grid_1_1_grid.html">00038</a> <span class="keyword">class </span><a class="code" href="class_grid_1_1_grid.html">Grid</a>
<a name="l00039"></a>00039 {
<a name="l00040"></a>00040    <span class="keyword">public</span>:
<a name="l00041"></a>00041            
<a name="l00046"></a>00046       ~<a class="code" href="class_grid_1_1_grid.html">Grid</a>();
<a name="l00047"></a>00047       
<a name="l00053"></a>00053       <span class="keyword">static</span> <a class="code" href="class_grid_1_1_grid.html">Grid</a>* getInstance();
<a name="l00054"></a>00054       
<a name="l00059"></a>00059       <span class="keywordtype">void</span> setParameters();
<a name="l00060"></a>00060       
<a name="l00065"></a>00065       <span class="keywordtype">void</span> initialize();
<a name="l00066"></a>00066       
<a name="l00071"></a>00071       <span class="keywordtype">void</span> clear();
<a name="l00072"></a>00072       
<a name="l00077"></a>00077       <span class="comment">//void createUsers();</span>
<a name="l00078"></a>00078       
<a name="l00083"></a>00083       <span class="comment">//void createENodeBs();   </span>
<a name="l00084"></a>00084           
<a name="l00091"></a>00091       <span class="keywordtype">void</span> generateUserPosition( <a class="code" href="class_basic_1_1_position.html">Basic::Position</a>&amp; p, 
<a name="l00092"></a>00092                                  <span class="keywordtype">int</span>&amp; site, 
<a name="l00093"></a>00093                                  <span class="keywordtype">int</span>&amp; sector );
<a name="l00094"></a>00094       
<a name="l00101"></a>00101       <span class="keywordtype">void</span> generatePositionInsideTriangle( <a class="code" href="class_basic_1_1_position.html">Basic::Position</a>&amp; p, 
<a name="l00102"></a>00102                                            <span class="keywordtype">double</span> xMax);
<a name="l00103"></a>00103       
<a name="l00108"></a>00108       <span class="keywordtype">void</span> generatePositionInsideHexagon( <a class="code" href="class_basic_1_1_position.html">Basic::Position</a>&amp; p, 
<a name="l00109"></a>00109                                           <span class="keywordtype">int</span> index);
<a name="l00110"></a>00110       
<a name="l00115"></a>00115       <span class="keywordtype">int</span> getSector( <a class="code" href="class_basic_1_1_position.html">Basic::Position</a>&amp; p );
<a name="l00116"></a>00116       
<a name="l00122"></a>00122       <span class="keywordtype">void</span> generateAbsolutePosition( <a class="code" href="class_basic_1_1_position.html">Basic::Position</a>&amp; p, <span class="keywordtype">int</span> site );
<a name="l00123"></a>00123       
<a name="l00128"></a>00128       <span class="keywordtype">void</span> generateENodeBPosition( <a class="code" href="class_basic_1_1_position.html">Basic::Position</a>&amp; p, <span class="keywordtype">int</span>&amp; index );
<a name="l00129"></a>00129       
<a name="l00130"></a>00130       
<a name="l00131"></a>00131       
<a name="l00132"></a>00132    <span class="keyword">private</span>:
<a name="l00133"></a>00133       
<a name="l00139"></a>00139       <a class="code" href="class_grid_1_1_grid.html">Grid</a>();
<a name="l00140"></a>00140       
<a name="l00145"></a>00145       <span class="keywordtype">void</span> updateIndexes();
<a name="l00146"></a>00146       
<a name="l00151"></a>00151       <span class="keywordtype">string</span> name_;
<a name="l00152"></a>00152       
<a name="l00157"></a>00157       <span class="keyword">static</span> <a class="code" href="class_grid_1_1_grid.html">Grid</a>* instance_;     
<a name="l00158"></a>00158       
<a name="l00163"></a>00163       <span class="keywordtype">double</span> interSiteDistance_;  
<a name="l00164"></a>00164       
<a name="l00169"></a>00169       <span class="keywordtype">double</span> minimumDistance_;  
<a name="l00170"></a>00170       
<a name="l00175"></a>00175       <span class="keywordtype">int</span> numberENodeBs_;       
<a name="l00176"></a>00176       
<a name="l00181"></a>00181       <span class="keywordtype">int</span> numberUsers_;
<a name="l00182"></a>00182       
<a name="l00187"></a>00187       <span class="keywordtype">int</span> numberSites_;
<a name="l00188"></a>00188       
<a name="l00193"></a>00193       <span class="keywordtype">int</span> siteIndex_;
<a name="l00194"></a>00194       
<a name="l00199"></a>00199       <span class="keywordtype">int</span> triangleIndex_;
<a name="l00200"></a>00200 };
<a name="l00201"></a>00201 
<a name="l00202"></a>00202 };
<a name="l00203"></a>00203 
<a name="l00204"></a>00204 <span class="preprocessor">#endif</span>
</pre></div></div><!-- contents -->
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Friends</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>



<hr class="footer"/><address class="footer"><small>
Generated on Thu Oct 25 2012 22:25:34 for LTE-UNB by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.7.6.1
</small></address>

</body>
</html>
